# To change this template, choose Tools | Templates
# and open the template in the editor.

class Realm
  attr_reader :name, :type, :battlegroup, :queue, :status, :population, :slug
  def initialize (name, type, battlegroup, queue, status, population, slug)
    @name = name
    @type = type
    @battlegroup = battlegroup
    @queue = queue
    @status = status
    @population = population
    @slug = slug
  end

  def online?
    if @status
      "Online"
    else
      "Offline"
    end
  end

  def to_s
    "#{online?}\t#{@name}\t#{@type}\t#{@population}\t#{@battlegroup}"
  end
end
